package bairui.international.console.web.controller.finance.score;

import com.lianjing.sh.spring.web.controller.enhance.module.Module;
import com.lianjing.sh.spring.web.controller.enhance.module.ModuleHead;
import com.lianjing.sh.spring.web.controller.enhance.module.body.InfoModuleBody;
import com.lianjing.sh.spring.web.controller.enhance.output.bean.DataDisplay;
import com.lianjing.sh.spring.web.controller.enhance.output.bean.DataType;
import com.lianjing.sh.spring.web.controller.enhance.output.bean.OutputBean;
import com.lianjing.sh.spring.web.controller.enhance.output.bean.OutputBeanGroup;
import com.lianjing.sh.spring.web.controller.enhance.output.bean.OutputType;
import com.lianjing.sh.spring.web.controller.enhance.output.bean.OutputWay;

/**
 *
 * Module_OrderInfo
 *
 */
class Module_OrderInfo{

	
	/**
	 * 信息模块
	 */
	public Module module(
		Module_OrderInfo_OutputModel bean, 
		C_Finance_ProductScoreOrder_NoPass_AddAccess.AddAccess.Operate c_Finance_ProductScoreOrder_NoPass_AddAccess_AddAccess_Operate
	,	C_Finance_ProductScoreOrder_Pass_Get.Get.Operate c_Finance_ProductScoreOrder_Pass_Get_Get_Operate
	){
		return
			new Module(
					new ModuleHead("订单信息")
						.addOperate(
							c_Finance_ProductScoreOrder_NoPass_AddAccess_AddAccess_Operate
								.defaultComment("审核不通过")
								.defaultTarget(com.lianjing.sh.spring.web.controller.base.operate.OperateTarget.Popup)
						)
						.addOperate(
							c_Finance_ProductScoreOrder_Pass_Get_Get_Operate
								.defaultComment("审核通过")
						)
					, 
					new InfoModuleBody(
								bean
							,
							new OutputBeanGroup(
									OutputWay.Vertical, 
									OutputData.info()
								)
						)
				);
	}
	
	/**
	 * 输出信息
	 */
	private static class OutputData {
	
		private static final OutputBean[] info() {
			OutputData outputData = new OutputData();
			return new OutputBean[]{
						outputData.getId(),
						outputData.getNumber(),
						outputData.getSubmitDate(),
						outputData.getScore(),
						outputData.getState(),
				};
		}
	
		OutputBean getId(){
			return new OutputBean("id", "", true, DataDisplay.Hide, DataType.Long, new OutputType[]{OutputType.Ajax, OutputType.Excel, }, "yy/MM/dd HH:mm:ss");
		}
		OutputBean getNumber(){
			return new OutputBean("number", "订单编号", true, DataDisplay.Show, DataType.String, new OutputType[]{OutputType.Ajax, OutputType.Excel, }, "yy/MM/dd HH:mm:ss");
		}
		OutputBean getSubmitDate(){
			return new OutputBean("submitDate", "提交时间", true, DataDisplay.Show, DataType.Date, new OutputType[]{OutputType.Ajax, OutputType.Excel, }, "yy/MM/dd HH:mm:ss");
		}
		OutputBean getScore(){
			return new OutputBean("score", "积分", true, DataDisplay.Show, DataType.Double, new OutputType[]{OutputType.Ajax, OutputType.Excel, }, "yy/MM/dd HH:mm:ss");
		}
		OutputBean getState(){
			return new OutputBean("state", "状态", true, DataDisplay.Show, DataType.Enum, new OutputType[]{OutputType.Ajax, OutputType.Excel, }, "yy/MM/dd HH:mm:ss");
		}
	}
	
	
	
	
	/**
	 * 输出模型
	 */
	

}
